import { httpSevice } from './request.js'
let token = uni.getStorageSync('tokey');
export function login(data) {
    return httpSevice({
      url: '/public/wxuser/login',
      method: 'GET',
      data: data
    })
};
export function regist(data) {
    return httpSevice({
      url: '/public/wxuser/regist',
      method: 'GET',
      data: data
    })
};
// 修改密码
export function repassword(data) {
    return httpSevice({
      url: '/wx/rePassword',
      method: 'GET',
      data: data
    })
};
export function wxSaveAccount(data) {
    return httpSevice({
      url: '/wx/saveAccount',
      method: 'POST',
      data: data
    })
};

export function wxListAccount(data) {
    return httpSevice({
      url: '/wx/listAccount',
      method: 'GET',
      data: data
    })
};

export function wxdelAccount(data) {
    return httpSevice({
      url: '/wx/delAccount',
      method: 'GET',
      data: data
    })
};

//obj.appid, obj.secret, obj.code

// 接口获取 sessionkey
// export const htxcx = (appid,secret,code)=>uniAjax()

// 解密手机号
// export const getPhone = (obj)=>uniAjax(BASE_URL_dev+"/getWxUserInfo",obj,"POST")

// 接口获取 openid
export function getOpenid(data) {
    return httpSevice({
      url: '/public/wxuser/openid',
      method: 'GET',
      data: data
    })
};
// 解密手机号
export function decode(data) {
    return httpSevice({
      url: '/public/wxuser/decode',
      method: 'GET',
      data: data
    })
};
